A Tested Semantics for the Python Programming Language
نویسندگان
چکیده
We present a small-step operational semantics for the Python programming language. We present both a core language for Python, suitable for tools and proofs, and a translation process for converting Python source to this core. We have tested the composition of translation and evaluation of the core for conformance with the primary Python implementation, thereby giving confidence in the fidelity of the semantics. We briefly report on the engineering of these components. Finally, we examine subtle aspects of the language, identifying scope as a pervasive concern that even impacts features that might be considered orthogonal.
منابع مشابه
InRaDoS: An internal radiation dosimetry computer program
Introduction: Internal radiation dosimetry is important from a radiation protection point of view and can help to optimize the radiation dose delivered to the workers, public, and patients. It has a rather simple protocol but needs a large amount of data. Therefore, it is difficult to do on a routine basis. The use of computer programs makes internal radiation dosimetry simpler...
متن کاملDeclarative Semantics in Object-Oriented Software Development - A Taxonomy and Survey
One of the modern paradigms to develop an application is object oriented analysis and design. In this paradigm, there are several objects and each object plays some specific roles in applications. In an application, we must distinguish between procedural semantics and declarative semantics for their implementation in a specific programming language. For the procedural semantics, we can write a ...
متن کاملPySBQL - Python-like query language constructed using stack base approach
PySBQL (Python-like Stack Based Query Language) is a full scale programming and query language. Its syntax is based upon the Python’s syntax, which makes PySBQL highly readable and easy to use. Contrary to the classical approach in query languages, semantics is defined using a common structure for programming languages – the Environment Stack (ENVS). As a query language it is similar to SBQL pr...
متن کاملFrom Rewriting Logic, to Programming Language Semantics, to Program Verification
Rewriting logic has proven to be an excellent formalism to define executable semantics of programming languages, concurrent or not, and then to derive formal analysis tools for the defined languages with very little effort, such as model checkers. In this paper we give an overview of recent results obtained in the context of the rewriting logic semantics framework K, such as complete semantics ...
متن کاملPyonR: A Python Implementation for Racket
The Python programming language is becoming increasingly popular in a variety of areas, most notably among novice programmers, due to its readable syntax and extensive libraries. On the other hand, the Racket language and its DrRacket IDE have a tradition for being used to introduce Computer Science concepts to students. Besides, the Racket platform can be extended to support other programming ...
متن کامل